package com.bestescortbedsystem.entity;

import java.io.Serializable;

/**
 * ses_user_sharing_relation
 * @author 
 */
public class SesUserSharingRelation implements Serializable {
    /**
     * ID,主键PK
     */
    private Long relationid;

    /**
     * 医院表ID
     */
    private Long hospitalinfoid;

    /**
     * 医院科室表ID
     */
    private Long departmentid;

    /**
     * 高阶用户分成表ID
     */
    private Long usersharingid;

    private static final long serialVersionUID = 1L;

    public Long getRelationid() {
        return relationid;
    }

    public void setRelationid(Long relationid) {
        this.relationid = relationid;
    }

    public Long getHospitalinfoid() {
        return hospitalinfoid;
    }

    public void setHospitalinfoid(Long hospitalinfoid) {
        this.hospitalinfoid = hospitalinfoid;
    }

    public Long getDepartmentid() {
        return departmentid;
    }

    public void setDepartmentid(Long departmentid) {
        this.departmentid = departmentid;
    }

    public Long getUsersharingid() {
        return usersharingid;
    }

    public void setUsersharingid(Long usersharingid) {
        this.usersharingid = usersharingid;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        SesUserSharingRelation other = (SesUserSharingRelation) that;
        return (this.getRelationid() == null ? other.getRelationid() == null : this.getRelationid().equals(other.getRelationid()))
            && (this.getHospitalinfoid() == null ? other.getHospitalinfoid() == null : this.getHospitalinfoid().equals(other.getHospitalinfoid()))
            && (this.getDepartmentid() == null ? other.getDepartmentid() == null : this.getDepartmentid().equals(other.getDepartmentid()))
            && (this.getUsersharingid() == null ? other.getUsersharingid() == null : this.getUsersharingid().equals(other.getUsersharingid()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getRelationid() == null) ? 0 : getRelationid().hashCode());
        result = prime * result + ((getHospitalinfoid() == null) ? 0 : getHospitalinfoid().hashCode());
        result = prime * result + ((getDepartmentid() == null) ? 0 : getDepartmentid().hashCode());
        result = prime * result + ((getUsersharingid() == null) ? 0 : getUsersharingid().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", relationid=").append(relationid);
        sb.append(", hospitalinfoid=").append(hospitalinfoid);
        sb.append(", departmentid=").append(departmentid);
        sb.append(", usersharingid=").append(usersharingid);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}